The present invention relates to the generation of a control program for a hardware accelerator from an application source code in any processor-based system, using a novel compilation method. This invention describes a method for automatically generating the program of the controller for an accelerator starting from an application source code, i.e., a sequential high-level language description of the application. The compilation method disclosed improves the performance of the accelerator by parallelising the operations of the accelerator.
Processor-based systems using multiple accelerators are designed to perform tasks such as mathematical calculation, signal processing, etc., in a rapid and cost efficient manner. Processor-based systems typically have a large software component that can be easily changed or modified, even after the system has been built. Also, these software components do not need significant hardware resources other than additional memory, as they run on the existing processors. To control software development costs, it is necessary to write the application using high-level languages such as C/C++, Java, etc., because writing in assembly language is prohibitively expensive both in terms of time and money. Applications written in high-level languages also have the advantage of being portable across different processors.
The disadvantage of using software components in processor-based systems includes reduced performance and increased power consumption. Contemporary embedded systems are rapidly increasing in complexity in terms of the functionality provided. Further, due to market demand, such systems are expected to provide superior performance and power efficiency at a lower cost. Moving more functionality to software may not meet the performance and power goals of the system. Hardware accelerators that perform specific computation intensive tasks of the application can be added to the system to provide the required performance boost. Adding such accelerators also reduces the overall power requirement of the system.
Application specific hardware accelerators suffer from the disadvantage of being relatively fixed, i.e., inflexible, and require long design and development cycles. To incorporate flexibility in the processor based system, the hardware accelerators can be built with a limited amount of programmability. This programmability allows the use of the same accelerator to perform different tasks, and also for modification of the functionality after the system has been built. Further, to avoid long design time, an automatic approach that can generate the application specific programmable accelerator and the control program that executes on the accelerator is needed.
The invention applies parallelisation techniques to improve the performance of the accelerator.
By way of example, this invention describes the compilation method using the C software language as the high-level language. However, the compilation method is generic and is applicable to an application written in other high-level languages such as C++, Java, etc.